package com.zhz.system.contract.enums;

import com.zhz.common.tool.mybatisplus.base.core.enums.EnumValueResolver;
import com.zhz.common.tool.mybatisplus.base.core.enums.IEnum;
import lombok.AllArgsConstructor;

/**
 * 权限类型
 *
 * @author zhouhengzhe
 * @date 2023/3/30
 */
@AllArgsConstructor
public enum PermissionTypeEnum implements EnumValueResolver<PermissionTypeEnum, Integer>, IEnum<Integer> {
    /**
     * 权限类型 1为菜单 2为功能 3为API
     */
    PERMISSION_MENU(1, "菜单"),
    PERMISSION_POINT(2, "功能"),
    PERMISSION_API(3, "API");

    private final Integer code;
    private final String message;

    /**
     * 获取枚举值
     */
    @Override
    public Integer getCode() {
        return this.code;
    }

    /**
     * 获取枚举描述
     */
    @Override
    public String getMessage() {
        return this.message;
    }
}
